# -*- coding: utf-8 -*-
import sys,os
sys.path.append("..")
import unittest

from bu19 import get19bucode
from yun13 import get13yuncode

class test13yun(unittest.TestCase):
    """
    """
    def testgood(self):
        dic = {
        u"卡":'1',
        u"冬":'13',
        u"江":'12',
        u"一":'4',
        u"灰":'7',
        u"由":'9',
        u"波":'2',
        u"人":'11',
        u"言":'10',
        u"鹅":'3',
        u"斜":'3',
        u"怀":'6',
        u"姑":'5',
        u"遥":'8',
        }
        for k in dic.keys():
            self.assertEqual(get13yuncode(k).count(dic[k]),1)

class test19bu(unittest.TestCase):
    """
    """
    def testgood(self):
        dic = {
        u"A":[],
        u"许":['4.2.1'],
        u"办":['7.2.2'],
        u"镇":['6.2.1','6.2.2'],
        u"积":['3.2.2','17.1'],
        }
        for k in dic.keys():
            self.assertEqual(get19bucode(k),dic[k])

if __name__ == "__main__":
    unittest.main()

